<!-- Content Header (Page header) -->
<section class="content-header">
    <h1>
        IPPI Admin Member
    </h1>
    <ol class="breadcrumb">
        <li><a href="<?php echo base_url("admin_home");?>"><i class="fa fa-dashboard"></i> Home</a></li>
        <li><a href="<?php echo base_url("admin_member");?>">Member</a></li>
        <li class="active">Detail</li>
    </ol>
</section>
<!-- Main content -->
<section class="content">
    <!-- Main row -->
    <div class="row">
        <div class='col-md-12'>
            <div class='box'>
                <div class='box-header'>
                    <h3 class='box-title'>Detail Data<small> Member</small></h3>
                    <!-- tools box -->
                    <div class="pull-right box-tools">
                        <button class="btn btn-default btn-sm" data-widget='collapse' data-toggle="tooltip" title="Collapse"><i class="fa fa-minus"></i></button>
                    </div><!-- /. tools -->
                </div><!-- /.box-header -->
                <div class='box-body pad'>
                    <?php
                    if(isset($success_status)){
                        ?>
                    <div id="msg_success" class="alert alert-success alert-dismissable">
                        <i class="fa fa-check"></i>
                        <button type="button" class="close" data-dismiss="alert" aria-hidden="true">x</button>
                        <b>Congratulation!</b> Data has been updated.
                    </div>
                    <div id="msg" class="alert alert-danger alert-dismissable">
                        <i class="fa fa-ban"></i>
                        <button type="button" class="close" data-dismiss="alert" aria-hidden="true">x</button>
                        <b>Alert!</b> Danger alert preview. This alert is dismissable. A wonderful serenity has taken possession of my entire soul, like these sweet mornings of spring which I enjoy with my whole heart.
                    </div>                    
                        <?php
                    }
                    else{
                    ?>
                    <div id="msg" class="alert alert-danger alert-dismissable">
                        <i class="fa fa-ban"></i>
                        <button type="button" class="close" data-dismiss="alert" aria-hidden="true">x</button>
                        <b>Alert!</b> Danger alert preview. This alert is dismissable. A wonderful serenity has taken possession of my entire soul, like these sweet mornings of spring which I enjoy with my whole heart.
                    </div>
                    <?php
                    }
                    ?>
                    <form role="form" action="" method="post" enctype="multipart/form-data" id="frm_member_update">
                        <?php
                        foreach($list_data as $r):
                        ?>
                        <input type="hidden" id="id" value="<?php echo $r->id_member;?>" />
                        <div class="form-group">
                            <label>Email</label>
                            <input type="email" readonly="" class="form-control" value="<?php echo $r->email;?>" placeholder="Input member email"/>
                        </div>
                        <div class="form-group">
                            <label>Name</label>
                            <input id="name" type="text" name="name" class="form-control" value="<?php echo $r->name;?>" placeholder="Input member name"/>
                        </div>
                        <div class="form-group">
                            <label>Status</label>
                            <select class="form-control" id="status" name="status">
                                <option value="1" <?php if($r->status == 1){echo "selected";}?>>Active</option>
                                <option value="0" <?php if($r->status == 0){echo "selected";}?>>Banned</option>
                            </select>
                        </div>
                        <?php
                        endforeach;
                        ?>
                        <div class="form-group" style="border-top: 1px dotted #ddd;padding-top: 20px;">
                            <button type="submit" class="btn btn-primary">Update Data</button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>    
</section>